import request from '../utils/request';

export async function getBookList() {
  return request('/wyApi/api/book');
}

export async function getBookDetail(id) {
  return request(`/wyApi/api/book/${id}`);
}

export async function buy(payload) {
  return request(`/wyApi/api/book/buy`, {method: 'POST', ContentType: 'multipart/form-data', body: payload})
}